<template>
  <div class="child">
    <h3>Child</h3>
    <input type="text" :value="value" @input="$emit('input',$event.target.value)"/>
    <button @click="$emit('input',3)">修改父组件的数据</button>
  </div>
</template>

<script>
export default {
    name:"Props",
    props:["value"]
}
</script>

<style scoped>
.child{
    background: yellowgreen;
}
</style>